<template>
  <div class="dashboard-container">
    <div>
      <span>发文编号：{{ data.fwbh }}</span>
      <span>发文日期：{{ data.fwrq }}</span>
    </div>
    <div v-for="item in data.zjzlist" :key="item.id">
      <span>{{ item.name }}</span>
      <div>
        <span v-for="(index,val) in item.list" :key="index">
          <el-tag> {{ val }} </el-tag>
        </span>
      </div>
    </div>
  </div>
</template>

<script>
// 引用api的zjklist 方法
export default {
  name: '',
  data() {
    return {
      data: {
        code: 2000,
        fwbh: '2018001',
        fwrq: '2018-01-10',
        zjzlist: [
          { 'id': '1','name': '施工组','count': '10','list': ['11','ss','ff','gg','hh','ss'] },
          { 'id': '2','name': '施工组','count': '10','list': ['11','ss','ff','gg','hh','ss'] }]
      }
    }
  },
  created() {
    // 初始化调接口
    this.initData()
  },
  methods: {
    // 初始化调接口
    initData() {
      // 调接口里面的方法
      // zjklist({ contractId: this.$route.query.contractid, year: year ,month: month }).then(data => {
      //   this.data = data
      //   if (data.zjzlist.length && data.zjzlist.length > 0) {
      //     // 跳转到编辑页
      //   }
      // })
    }
  }
}

</script>

<style rel="stylesheet/scss" lang="scss" scoped>
</style>
